<script src="/static/lib/layui/layui.js"></script>
<script>
    var data = [{
        title: "视频管理平台",
        children: [{
            title: "UserTree",
            children:[{
                title: "11",
            }]
        },{
            title: "2",
        }]
    }];

    layui.use('tree', function(){
        var tree = layui.tree

        tree.render({
            elem: '#tree',
            data: data,
            click: function (node){
                alert(node.data.title);
            },
            id: 'treeId',
        });
    });
</script>